package proxy

import "math/rand"

type ServerList struct {
	servers []string
}

func (s ServerList) getRandomServer() string {
	if len(s.servers) == 0 {
		return ""
	}

	randIndex := rand.Int() % len(s.servers)
	return s.servers[randIndex]
}

var (
	BackendServers ServerList
)
func init() {
	BackendServers = ServerList{
		servers: []string{ "localhost:8080", },
	}
}